from django.db import models

# Create your models here.
class ContentInfo(models.Model):
    # db_table = "user"
    content_name = models.CharField(max_length=50, null=False, default="未命名")
    content_intro = models.TextField(max_length=128, null=True)
    content_image = models.TextField(max_length=500, null=True)
    content_auth_id = models.IntegerField(null=True)
    content_text = models.TextField(max_length=500, null=True)
    content_star_number =models.IntegerField(default=0, null=True)
    content_comment_number = models.IntegerField(default=0, null=True)
    content_comment_id = models.TextField(max_length=512, null=True)
    content_type = models.CharField(max_length=64, null=False, default="其他")

class CommentInfo(models.Model):
    comment_text = models.TextField(max_length=512, null=False)
    comment_user_id = models.IntegerField()
    comment_reply = models.IntegerField(default=None)
    comment_star_number = models.IntegerField(default=0)
